/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Metodos;

import BD.CriaConexao;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.util.logging.Level;
import java.util.logging.Logger;

/**
 *
 * @author André
 */
public class MinimizaTela {
private Connection conexao;
public MinimizaTela(){
        try {
            this.conexao=(Connection) CriaConexao.getConexao();
        } catch (SQLException ex) {
            Logger.getLogger(MinimizaTela.class.getName()).log(Level.SEVERE, null, ex);
        }
}
    public  void Minimiza(int i) throws SQLException {
        String sql="update layout1 set id=?";
        PreparedStatement consulta=(PreparedStatement) conexao.prepareStatement(sql);
                   
            consulta.setInt(1, i);
            
            consulta.execute();
            consulta.close();
    }
    
}
